<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box {
            width: 600px;
            height: 600px;
            margin: 50px auto;
            border: 1px solid greenyellow;
            position: relative;
        }

        .ball {
            width: 100px;
            height: 100px;
            border-radius: 50%;
            background: orangered;
            position: absolute;
            top: 50px;
            left: 50%;
            margin-left: -50px;
            animation: move 0.5s cubic-bezier(0.5, 0.05, 1, 0.5) infinite alternate;

        }

        @keyframes move {
            from {
                transform: translateY(0);
            }

            to {
                transform: translateY(250px);
            }
        }

        .shadow {
            position: absolute;
            width: 100px;
            height: 50px;
            border-radius: 50%;
            background: #ccc;
            top: 400px;
            left: 50%;
            margin-left: -50px;

            /* cubic-bezier(0.5, 0.05, 1, 0.5) */
            animation: move1 0.5s cubic-bezier(0.5, 0.05, 1, 0.5) infinite alternate;
        }

        @keyframes move1 {
            0% {
                opacity: 0.5;
                transform: scale(0.7);
            }

            100% {
                opacity: 0.1;
                transform: scale(1);
            }

        }
    </style>
</head>

<body>
    <div class="box">
        <div class="ball"></div>
        <div class="shadow"></div>
    </div>
</body>

</html>